package com.hy.singleton;

/**
 * Created With IntelliJ IDEA.
 * Descriptions:
 * <p>
 * User:Mr.Du
 * Date:2024/8/8
 * Time:17:36
 */
public class LazySingletonSecSynchronized {

    public static LazySingletonSecSynchronized instance;

    private LazySingletonSecSynchronized() {}

    public static synchronized LazySingletonSecSynchronized getInstance() {
        if(instance == null){
            instance = new LazySingletonSecSynchronized();
        }
        return instance;
    }
}
